<%@ page language="java" import="java.util.*,entitybean.oc_user_name.EntityBeanOc_User_Name;" pageEncoding="utf-8"%>
<%EntityBeanOc_User_Name e=(EntityBeanOc_User_Name)request.getAttribute("e"); %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>adminindex</title>
<link href="../../css/style.css" rel="stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="<%=request.getContextPath()%>/My97DatePicker/WdatePicker.js"></script>
<script type="text/javascript" src="dwr/engine.js">
</script>
		<script type="text/javascript" src="dwr/util.js">
</script>
		<script type="text/javascript" src="dwr/interface/voyage.js">
</script>

<script language="javascript">
function  update_me(){   
    var id=document.getElementById("id").value;
    var username=document.getElementById("username").value;
	var realname=document.getElementById("realname").value;
	var password=document.getElementById("password").value;
	var email=document.getElementById("email").value;
	var id_card=document.getElementById("id_card").value;
	var backup=document.getElementById("backup").value;
	var last_action=document.getElementById("last_action").value;
	if(username==""){
		window.alert("用户名不得为空!");
		return false;
	}
	if(realname==""){
		window.alert("真实姓名不得为空！");
		return false;
	}
	if(password==""){
		window.alert("密码不得为空！");
		return false;
	}
	if(email==""){
		window.alert("EMAIL不得为空!");
		return false;
	}
	if(id_card==""){
		window.alert("身份证不得为空！");
		return false;
	}
	if(backup==""){
		window.alert("申请理由不得为空！");
		return false;
	}
	if(last_action==""){
		window.alert("到期时间不能为空！");
		return false;
	}
	voyage.Ajax_voyage_load_username_id(id+","+username+","+email, checkerA);
}
function checkerA(str) {
   if(str=="1"){
      alert("用户名重复,不能添加");
      return false;
   }
   if(str=="2"){
      alert("Email重复,不能添加");
      return false;
   }
   var url="<%=request.getContextPath()%>/admin_update_admin_info.do?method=admin_update_admin_info&v="+Math.random();
   document.getElementById("form1").action=url;
   document.getElementById("form1").submit();
}
</script>

<style>
body{
	background-color: #EAEBE3;
}
</style>
</head>
<body>


<div class="admin_nei">


<div class="xge">
  <!--<div class="xgetitle"><img src="../../images/admin_38.jpg" alt="" /></div> -->
  <div class="gt">
    
    
    
    <div class="gtt">
   <form id="form1" name="form1" method="post" action="">
   <table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#a0a297">
     <tr>
       <td bgcolor="#eaebe3">会员详细</td>
       </tr>
   </table>
   <table width="100%" border="0" cellpadding="5" cellspacing="1" bgcolor="#E6E6E6" id="admintxt">
     <tr>
       <td width="14%" align="right" bgcolor="#FFFFFF">用户名：</td>
       <td width="86%" bgcolor="#FFFFFF"><input type="text" value="<%=e.getUsername()%>" name="username" id="username" /></td>
       </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">邮箱：</td>
       <td bgcolor="#FFFFFF"><input value="<%=e.getEmail()%>" type="text" name="email" id="email" /></td>
       </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">身份证：</td>
       <td bgcolor="#FFFFFF"><input type="text" name="id_card" id="id_card" value="<%=e.getId_card() %>" /></td>
       </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">姓名：</td>
       <td bgcolor="#FFFFFF"><input type="text" value="<%=e.getRealname()%>" name="realname" id="realname" /></td>
     </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">密码：</td>
       <td bgcolor="#FFFFFF"><input  value="<%=e.getPassword()%>" type="text" name="password" id="password" /></td>
     </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">查看理由：</td>
       <td bgcolor="#FFFFFF"><input value="<%=e.getBackup()%>" type="text" name="backup" id="backup" /></td>
     </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">设置到期时间：</td>
       <td bgcolor="#FFFFFF"><input value="<%=e.getLast_action()%>" name="last_action" type="text" id="last_action" class="Wdate" style="width:150px" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd'})" readonly="readonly" /></td>
     </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">是否激活：</td>
       <td bgcolor="#FFFFFF"><select name="isactive" id="isactive">
         <option value="ON" <%if(e.getIsactive().equals("ACT")){ %> selected <%} %>>激活</option>
         <option value="OFF" <%if(e.getIsactive().equals("OFF")){ %> selected <%} %>>未激活</option>
       </select></td>
     </tr>
     <tr>
       <td align="right" bgcolor="#FFFFFF">&nbsp;</td>
       <td bgcolor="#FFFFFF"> <input type="hidden" name="id" id="id" value="<%=e.getId()%>"/>
       <input type="button" name="button" id="button" value="提交" onclick="update_me()" /></td>
     </tr>
     
   </table>
   </form>
 </div>
    
    
    
    
    </div>
  
</div>
</div>







</body>
</html>
